from typing import Final

# 定义聊天页面元素查找特征常量
CHAT_TITLE: Final = "ChatGPT"
# PROMPT_TEXTAREA_SELECTOR: Final = "tag:textarea@|data-id=root@|#prompt-textarea@|data-id^request-WEB"
PROMPT_TEXTAREA_SELECTOR: Final = "#prompt-textarea"
# PROMPT_TEXTAREA_SELECTOR: Final = "tag:textarea@@data-id=root"
SEND_BUTTON_SELECTOR: Final = "tag:button@@data-testid=send-button"
LOAD_CHATGPT_TIME: Final = "load_chatgpt_time"

# 系统用到的缓存key
LISTEN_STATE: Final[str] = "listen_state"
"""系统监听状态：1监听，0停止监听 代表要退出"""
CHAT_STATE: Final[str] = "chat_state"
"""聊天状态：1新对话，2对话中"""
CHAT_RECORDS_LAST: Final[str] = "chat_records_last"
"""最后一次聊天记录的文件名"""
CHAT_MESSAGE: Final[str] = "chat_message"
"""聊天的问题"""
CHAT_RECORDS_START: Final[str] = "chat:records:start:"
"""聊天对话的组id,用来标记已经完成的对话"""
CHAT_MESSAGE_ANSWER: Final[str] = "chat_message_answer"
"""聊天的回答"""
CHAT_RECORDS: Final[str] = "chat:records:"
"""聊天的回答id,用来标记当前对话保存时间"""
ANSWER_MARKDOWN: Final[str] = "chat_message_answer_markdown"
"""获取聊天内容的格式0：markdown，1：html"""
WEB_CSS: Final[str] = "web_css"
"""聊天页面的css样式"""
